// vant-components.js
const {
  Button,
  Icon,
  Toast,
  Checkbox,
  CheckboxGroup,
  Swipe,
  SwipeItem,
  Lazyload,
  Popup,
  SwipeCell,
  Loading,
  Dialog,
  NoticeBar,
  Field,
  CellGroup
} = vant

const vantComponents = [
  Button,
  Icon,
  Toast,
  Checkbox,
  CheckboxGroup,
  Swipe,
  SwipeItem,
  Lazyload,
  Popup,
  SwipeCell,
  Loading,
  Dialog,
  NoticeBar,
  Field,
  CellGroup
]

const VantPlugin = {
  install (app) {
    vantComponents.forEach(component => {
      app.use(component)
    })
  }
}
